# Contributor: Marcel Wysocki <maci@satgnu.net>
 
pkgname=snes9x-gtk
pkgver=1.51.74
pkgrel=1
pkgdesc="GTK+ Version of snes9x, a portable Emulator for the Super Nintento Entertainment System"
url="http://snes9x.com/phpbb2/viewtopic.php?t=3703"
arch=('i686' 'x86_64')
license=('custom: snes9x')
depends=('libxtst' 'sdl' 'nasm' 'mesa' 'gtkglext' 'portaudio' 'libglade')
makedepends=(intltool)
source=(http://snes9x-gtk.googlecode.com/files/snes9x-1.51-src-gtk-74.tar.bz2)
md5sums=('d104d1668ac39d6de822ff43feb979fb')
 
build() {
 
  # build snes9x-gtk with opengl
  cd $srcdir/snes9x-1.51-src/gtk
  ./configure --prefix=/usr --with-gtk --with-opengl --with-netplay --disable-warn 
  make || return 1
 
  #Manually install the package
  install -D -m755 snes9x-gtk $pkgdir/usr/bin/snes9x-gtk
 
  #Install the .desktop and icon files
  install -D -m644 data/snes9x.desktop $pkgdir/usr/share/applications/snes9x.desktop
  install -D -m644 data/snes9x.svg $pkgdir/usr/share/pixmaps/snes9x.svg
 
  #Install the license
  install -D -m644 $srcdir/snes9x-1.51-src/doc/snes9x-license.txt $pkgdir/usr/share/licenses/snes9x-gtk/COPYING
 
}
 
# vim:set ts=2 sw=2 et:
